package com.system.healthproject.model.sickuser.service.imp;

import com.system.healthproject.mapper.BannerMapper;
import com.system.healthproject.mapper.PatientMapper;
import com.system.healthproject.model.sickuser.service.PatientBannerService;
import com.system.healthproject.pojo.Banner;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class PatientBannerServiceImpl implements PatientBannerService {
   @Autowired
   private PatientMapper patientMapper;
   @Autowired
   private BannerMapper bannerMapper;




    /**
     * 根据登陆ID查询患者ID
     * @param loginId
     * @return
     */
    private Integer selectPatientId(Integer loginId){
        return patientMapper.selectPatientId(loginId);
    }

    /**
     * 查询患者端banner图
     * @return
     */
    @Override
    public List<Banner> selectPatientBanner() {
        return bannerMapper.selectPatientBanner();
    }

    @Override
    public Banner selectPatientBannerInfo(Integer bannerId) {
        return bannerMapper.selectPatientBannerInfo(bannerId);
    }
}
